<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.18"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>aws-crt-cpp: /home/ANT.AMAZON.COM/dengket/doc/aws-crt-cpp/include/aws/crt/io/Bootstrap.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">aws-crt-cpp
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.18 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="dir_076842b242c291358044feb169933571.html">aws</a></li><li class="navelem"><a class="el" href="dir_cc4322e4b2151c90adb7cd2e3f54423a.html">crt</a></li><li class="navelem"><a class="el" href="dir_b90b4e231cf9df4b6b8451850277e486.html">io</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">Bootstrap.h</div>  </div>
</div><!--header-->
<div class="contents">
<a href="Bootstrap_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="preprocessor">#pragma once</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment">/*</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment"> * Copyright 2010-2018 Amazon.com, Inc. or its affiliates. All Rights Reserved.</span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="comment"> * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;).</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="comment"> * You may not use this file except in compliance with the License.</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="comment"> * A copy of the License is located at</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="comment"> *  http://aws.amazon.com/apache2.0</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="comment"> * or in the &quot;license&quot; file accompanying this file. This file is distributed</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="comment"> * on an &quot;AS IS&quot; BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either</span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="comment"> * express or implied. See the License for the specific language governing</span></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="comment"> * permissions and limitations under the License.</span></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160; </div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;<span class="preprocessor">#include &lt;<a class="code" href="Exports_8h.html">aws/crt/Exports.h</a>&gt;</span></div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="preprocessor">#include &lt;<a class="code" href="Types_8h.html">aws/crt/Types.h</a>&gt;</span></div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;<span class="preprocessor">#include &lt;<a class="code" href="EventLoopGroup_8h.html">aws/crt/io/EventLoopGroup.h</a>&gt;</span></div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="preprocessor">#include &lt;<a class="code" href="HostResolver_8h.html">aws/crt/io/HostResolver.h</a>&gt;</span></div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160; </div>
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;<span class="preprocessor">#include &lt;aws/io/channel_bootstrap.h&gt;</span></div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;<span class="preprocessor">#include &lt;aws/io/host_resolver.h&gt;</span></div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160; </div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;<span class="preprocessor">#include &lt;future&gt;</span></div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160; </div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;<span class="keyword">namespace </span><a class="code" href="namespaceAws.html">Aws</a></div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;{</div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;    <span class="keyword">namespace </span>Crt</div>
<div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;    {</div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;        <span class="keyword">namespace </span>Io</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;        {</div>
<div class="line"><a name="l00033"></a><span class="lineno"><a class="line" href="namespaceAws_1_1Crt_1_1Io.html#a3284b8b9a955c2b24fd3d095350f22e1">   33</a></span>&#160;            <span class="keyword">using</span> <a class="code" href="namespaceAws_1_1Crt_1_1Io.html#a3284b8b9a955c2b24fd3d095350f22e1">OnClientBootstrapShutdownComplete</a> = std::function&lt;void()&gt;;</div>
<div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160; </div>
<div class="line"><a name="l00044"></a><span class="lineno"><a class="line" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">   44</a></span>&#160;            <span class="keyword">class </span><a class="code" href="Exports_8h.html#a0a3f6c46aee6b588ce99a142cdb22d1d">AWS_CRT_CPP_API</a> <a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">ClientBootstrap</a> final</div>
<div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;            {</div>
<div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;              <span class="keyword">public</span>:</div>
<div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;                <a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">ClientBootstrap</a>(</div>
<div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160;                    <a class="code" href="classAws_1_1Crt_1_1Io_1_1EventLoopGroup.html">EventLoopGroup</a> &amp;elGroup,</div>
<div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160;                    <a class="code" href="classAws_1_1Crt_1_1Io_1_1HostResolver.html">HostResolver</a> &amp;resolver,</div>
<div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;                    <a class="code" href="namespaceAws_1_1Crt.html#a3c9efb213e2de565038afcfd4f8afcda">Allocator</a> *allocator = <a class="code" href="namespaceAws_1_1Crt.html#a7178ef65f261a8db52a624458331bbb2">g_allocator</a>) noexcept;</div>
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;                ~<a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">ClientBootstrap</a>();</div>
<div class="line"><a name="l00056"></a><span class="lineno"><a class="line" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#ac6669a24157928a6182dce6fbd0ed87e">   56</a></span>&#160;                <a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#ac6669a24157928a6182dce6fbd0ed87e">ClientBootstrap</a>(<span class="keyword">const</span> <a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">ClientBootstrap</a> &amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a name="l00057"></a><span class="lineno"><a class="line" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#a2f021dc61db7beb93e26c27c0cf5a790">   57</a></span>&#160;                <a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">ClientBootstrap</a> &amp;<a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#a2f021dc61db7beb93e26c27c0cf5a790">operator=</a>(<span class="keyword">const</span> <a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">ClientBootstrap</a> &amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a name="l00058"></a><span class="lineno"><a class="line" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#a615bc843746ff0c53ffef5cc71b8f935">   58</a></span>&#160;                <a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#a615bc843746ff0c53ffef5cc71b8f935">ClientBootstrap</a>(<a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">ClientBootstrap</a> &amp;&amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a name="l00059"></a><span class="lineno"><a class="line" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#ab1fb109bea4421f99529160cd9d64654">   59</a></span>&#160;                <a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">ClientBootstrap</a> &amp;<a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#ab1fb109bea4421f99529160cd9d64654">operator=</a>(<a class="code" href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">ClientBootstrap</a> &amp;&amp;) = <span class="keyword">delete</span>;</div>
<div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160; </div>
<div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;                <span class="keyword">operator</span> bool() const noexcept;</div>
<div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160; </div>
<div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;                <span class="keywordtype">int</span> <a class="code" href="namespaceAws_1_1Crt.html#aec41cfe367315d4e4e1712f19e3d3061">LastError</a>() const noexcept;</div>
<div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160; </div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;                <span class="keywordtype">void</span> SetShutdownCompleteCallback(<a class="code" href="namespaceAws_1_1Crt_1_1Io.html#a3284b8b9a955c2b24fd3d095350f22e1">OnClientBootstrapShutdownComplete</a> callback);</div>
<div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160; </div>
<div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160;                <span class="keywordtype">void</span> EnableBlockingShutdown() noexcept;</div>
<div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160;                aws_client_bootstrap *GetUnderlyingHandle() const noexcept;</div>
<div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160; </div>
<div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160;              private:</div>
<div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;                aws_client_bootstrap *m_bootstrap;</div>
<div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160;                <span class="keywordtype">int</span> m_lastError;</div>
<div class="line"><a name="l00098"></a><span class="lineno">   98</span>&#160;                std::unique_ptr&lt;struct ClientBootstrapCallbackData&gt; m_callbackData;</div>
<div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;                std::future&lt;<span class="keywordtype">void</span>&gt; m_shutdownFuture;</div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;                <span class="keywordtype">bool</span> m_enableBlockingShutdown;</div>
<div class="line"><a name="l00101"></a><span class="lineno">  101</span>&#160;            };</div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160;        } <span class="comment">// namespace Io</span></div>
<div class="line"><a name="l00103"></a><span class="lineno">  103</span>&#160;    }     <span class="comment">// namespace Crt</span></div>
<div class="line"><a name="l00104"></a><span class="lineno">  104</span>&#160;} <span class="comment">// namespace Aws</span></div>
</div><!-- fragment --></div><!-- contents -->
<div class="ttc" id="anamespaceAws_1_1Crt_html_a3c9efb213e2de565038afcfd4f8afcda"><div class="ttname"><a href="namespaceAws_1_1Crt.html#a3c9efb213e2de565038afcfd4f8afcda">Aws::Crt::Allocator</a></div><div class="ttdeci">aws_allocator Allocator</div><div class="ttdef"><b>Definition:</b> StlAllocator.h:25</div></div>
<div class="ttc" id="aEventLoopGroup_8h_html"><div class="ttname"><a href="EventLoopGroup_8h.html">EventLoopGroup.h</a></div></div>
<div class="ttc" id="aTypes_8h_html"><div class="ttname"><a href="Types_8h.html">Types.h</a></div></div>
<div class="ttc" id="aExports_8h_html_a0a3f6c46aee6b588ce99a142cdb22d1d"><div class="ttname"><a href="Exports_8h.html#a0a3f6c46aee6b588ce99a142cdb22d1d">AWS_CRT_CPP_API</a></div><div class="ttdeci">#define AWS_CRT_CPP_API</div><div class="ttdef"><b>Definition:</b> Exports.h:34</div></div>
<div class="ttc" id="aclassAws_1_1Crt_1_1Io_1_1HostResolver_html"><div class="ttname"><a href="classAws_1_1Crt_1_1Io_1_1HostResolver.html">Aws::Crt::Io::HostResolver</a></div><div class="ttdef"><b>Definition:</b> HostResolver.h:42</div></div>
<div class="ttc" id="anamespaceAws_1_1Crt_1_1Io_html_a3284b8b9a955c2b24fd3d095350f22e1"><div class="ttname"><a href="namespaceAws_1_1Crt_1_1Io.html#a3284b8b9a955c2b24fd3d095350f22e1">Aws::Crt::Io::OnClientBootstrapShutdownComplete</a></div><div class="ttdeci">std::function&lt; void()&gt; OnClientBootstrapShutdownComplete</div><div class="ttdef"><b>Definition:</b> Bootstrap.h:33</div></div>
<div class="ttc" id="anamespaceAws_1_1Crt_html_a7178ef65f261a8db52a624458331bbb2"><div class="ttname"><a href="namespaceAws_1_1Crt.html#a7178ef65f261a8db52a624458331bbb2">Aws::Crt::g_allocator</a></div><div class="ttdeci">Allocator * g_allocator</div><div class="ttdef"><b>Definition:</b> Api.cpp:28</div></div>
<div class="ttc" id="anamespaceAws_1_1Crt_html_aec41cfe367315d4e4e1712f19e3d3061"><div class="ttname"><a href="namespaceAws_1_1Crt.html#aec41cfe367315d4e4e1712f19e3d3061">Aws::Crt::LastError</a></div><div class="ttdeci">AWS_CRT_CPP_API int LastError() noexcept</div><div class="ttdef"><b>Definition:</b> Api.cpp:116</div></div>
<div class="ttc" id="aclassAws_1_1Crt_1_1Io_1_1ClientBootstrap_html_a2f021dc61db7beb93e26c27c0cf5a790"><div class="ttname"><a href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#a2f021dc61db7beb93e26c27c0cf5a790">Aws::Crt::Io::ClientBootstrap::operator=</a></div><div class="ttdeci">ClientBootstrap &amp; operator=(const ClientBootstrap &amp;)=delete</div></div>
<div class="ttc" id="aclassAws_1_1Crt_1_1Io_1_1EventLoopGroup_html"><div class="ttname"><a href="classAws_1_1Crt_1_1Io_1_1EventLoopGroup.html">Aws::Crt::Io::EventLoopGroup</a></div><div class="ttdef"><b>Definition:</b> EventLoopGroup.h:43</div></div>
<div class="ttc" id="aclassAws_1_1Crt_1_1Io_1_1ClientBootstrap_html_ab1fb109bea4421f99529160cd9d64654"><div class="ttname"><a href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#ab1fb109bea4421f99529160cd9d64654">Aws::Crt::Io::ClientBootstrap::operator=</a></div><div class="ttdeci">ClientBootstrap &amp; operator=(ClientBootstrap &amp;&amp;)=delete</div></div>
<div class="ttc" id="aclassAws_1_1Crt_1_1Io_1_1ClientBootstrap_html_ac6669a24157928a6182dce6fbd0ed87e"><div class="ttname"><a href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#ac6669a24157928a6182dce6fbd0ed87e">Aws::Crt::Io::ClientBootstrap::ClientBootstrap</a></div><div class="ttdeci">ClientBootstrap(const ClientBootstrap &amp;)=delete</div></div>
<div class="ttc" id="anamespaceAws_html"><div class="ttname"><a href="namespaceAws.html">Aws</a></div><div class="ttdef"><b>Definition:</b> Api.h:25</div></div>
<div class="ttc" id="aExports_8h_html"><div class="ttname"><a href="Exports_8h.html">Exports.h</a></div></div>
<div class="ttc" id="aclassAws_1_1Crt_1_1Io_1_1ClientBootstrap_html_a615bc843746ff0c53ffef5cc71b8f935"><div class="ttname"><a href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html#a615bc843746ff0c53ffef5cc71b8f935">Aws::Crt::Io::ClientBootstrap::ClientBootstrap</a></div><div class="ttdeci">ClientBootstrap(ClientBootstrap &amp;&amp;)=delete</div></div>
<div class="ttc" id="aclassAws_1_1Crt_1_1Io_1_1ClientBootstrap_html"><div class="ttname"><a href="classAws_1_1Crt_1_1Io_1_1ClientBootstrap.html">Aws::Crt::Io::ClientBootstrap</a></div><div class="ttdef"><b>Definition:</b> Bootstrap.h:45</div></div>
<div class="ttc" id="aHostResolver_8h_html"><div class="ttname"><a href="HostResolver_8h.html">HostResolver.h</a></div></div>
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.18
</small></address>
</body>
</html>
